﻿<%@ Page Language="C#" MasterPageFile="~/MasterPage/MobiMap.Master" AutoEventWireup="true" CodeBehind="ServiceDetail.aspx.cs" Inherits="MobiMap.Guest.ServiceDetail" Title="Untitled Page" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
<title>Service detail</title>
<script type="text/javascript">

    function Direction()
    {
        ShowHideDivDirection();
        var toHere = document.getElementById("<%=lbName.ClientID %>").innerHTML + ", "
                    + document.getElementById("<%=lbAddress.ClientID %>").innerHTML;
        FillDirection(toHere);
        var flag = document.getElementById("<%=hiddenFlag.ClientID %>");  
        var point = document.getElementById("hiddenPoint"); 
        point.value = "end";   
        
        ChangeValueHidden(flag.value + "_" + point.value); //startinfo or endinfo or homeinfo, startpoint or endpoint            
        
        return false;
    }
    
    function getFlagNode()
    {
        return document.getElementById("<%=hiddenFlag.ClientID %>");  
    }

    function SearchNearBy()
    {
        ShowHideDivService();
        var strNearBy = document.getElementById("<%=lbName.ClientID %>").innerHTML + ", "
                    + document.getElementById("<%=lbAddress.ClientID %>").innerHTML;
        FillNearBy(strNearBy);
        
        var flag = document.getElementById("<%=hiddenFlag.ClientID %>");
        ChangeValueHidden("nearby" + "_" + flag.value);
        return false;
    }

</script>

</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="mainArea" runat="server">
   
   <div align="center" class="divDetail_wrapper"> 
       <div class="addressResult_title">
           <asp:Label ID="lbDetailTitile" runat="server" Text="Detail"></asp:Label>
       </div>
        
        <div id="divDetail" class="divPlaceInfo">   
           
            <img id="imgPic" src="" width="96" height="96" alt="abc" runat="server" style="border: solid 1px Silver;"/>

            <b><asp:Label ID="lbName" runat="server" Text=""></asp:Label></b><br />
            <asp:Label ID="lbPlaceType" runat="server" Text=""></asp:Label><br />
            <br />
            <asp:Label ID="lbAddress" runat="server" Text=""></asp:Label><br />
            <asp:Label ID="lbPhone" runat="server" Text=""></asp:Label><br />
            <asp:Label ID="lbWebsite" runat="server" Text=""></asp:Label><br />
            <asp:Label ID="lbDescription" runat="server" Text=""></asp:Label> 
            <asp:HiddenField ID="hiddenID" runat="server"/>
            <input type="hidden" id="hiddenFlag" runat="server" value="" />
            <input type="hidden" id="hiddenPoint" value="" />
            <br /><br />           
            
        </div> 
        <hr style="width:80%" />
        <br />
        <input type="button" class="button" id="detailDirection" runat="server" onclick="Direction()" value="Direction" />
        <input type="button" class="button" id="detailNearBy" runat="server" onclick="SearchNearBy()" value="Pres de" /> 
    </div>   

</asp:Content>
